package com.campus.customer.controller;

import com.campus.customer.entity.Banner;
import com.campus.customer.service.BannerService;
import com.campus.common.bean.common.Resp;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * 轮播图表 前端控制器
 * </p>
 *
 * @author ZhaoYuJie
 * @since 2025-04-02
 */
@RestController
@RequestMapping("/banner")
public class BannerController {
    @Autowired
    private BannerService bannerService;

    @GetMapping("/list")
    public Resp<List<Banner>> list() {
        return Resp.success(bannerService.list());
    }
}
